package ods_supplier

import (
	"github.com/gin-gonic/gin"
	"server/middleware"
)

type SupplierRouter struct {
}

func (s *SupplierRouter) InitOdsSupplierRouter(Router *gin.RouterGroup) {
	odsSupplierRouter := Router.Group("odsSupplier").Use(middleware.OperationRecord())
	odsSupplierRouterWithoutRecord := Router.Group("odsSupplier")
	var odsSupplierApi = SupplierApi{}
	{
		odsSupplierRouter.POST("createOdsSupplier", odsSupplierApi.CreateOdsSupplier)
		odsSupplierRouter.DELETE("deleteOdsSupplier", odsSupplierApi.DeleteOdsSupplier)
		odsSupplierRouter.DELETE("deleteOdsSupplierByIds", odsSupplierApi.DeleteOdsSupplierByIds)
		odsSupplierRouter.PUT("updateOdsSupplier", odsSupplierApi.UpdateOdsSupplier)
	}
	{
		odsSupplierRouterWithoutRecord.GET("findOdsSupplier", odsSupplierApi.FindOdsSupplier)
		odsSupplierRouterWithoutRecord.GET("getAllOdsSuppliers", odsSupplierApi.GetAllOdsSuppliers)
		odsSupplierRouterWithoutRecord.GET("getOdsSupplierList", odsSupplierApi.GetOdsSupplierList)
		odsSupplierRouterWithoutRecord.GET("getOdsSupplierColLabel", odsSupplierApi.GetOdsSupplierColLabel)
	}
}
